﻿//Created by Action Script Viewer - http://www.buraks.com/asv
package net.wooga.pets.models {
    import __AS3__.vec.*;
    import net.wooga.pets.models.vo.*;
    import org.robotlegs.mvcs.*;

    public class PendingModel extends Actor {

        private var _pendingItems:Vector.<PendingItemVO>;

        public function PendingModel(){
            this._pendingItems = new Vector.<PendingItemVO>();
            super();
        }
        public function addPendingItem(_arg1:PendingItemVO):void{
            this._pendingItems.push(_arg1);
        }
        public function removePendingItem(_arg1:PendingItemVO):void{
            this._pendingItems.splice(this._pendingItems.indexOf(_arg1), 1);
        }
        public function getPendingItemCount(_arg1:String):int{
            var _local3:PendingItemVO;
            var _local2:int;
            for each (_local3 in this._pendingItems) {
                if (_local3.type == _arg1){
                    _local2 = (_local2 + _local3.amount);
                };
            };
            return (_local2);
        }

    }
}//package net.wooga.pets.models 
